import { stream } from "fetch-event-stream";

export async function chatSSE(tid: string, message: string) {
  return stream("/apis/chat/sse", {
    method: "POST",
    headers: { "content-type": "application/json" },
    body: JSON.stringify({ tid, message }),
  });
}
